﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;

namespace DFGK_WMS.Model.Models
{
    /// <summary>
    /// 库存流水
    /// </summary>
    [Table("TInventoryLogs")]
    [SqlSugar.SugarTable(TableName = "TInventoryLogs")]
    public partial class TInventoryLog
    {
        /// <summary>
        /// 编号
        /// </summary>
        [SqlSugar.SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
        public int Id { get; set; }
        /// <summary>
        /// 来源单据类型：0:-入库；1-出库；2-盘点；3-手工调整；4-库存调整；
        /// </summary>
        public int? SourceType { get; set; }
        /// <summary>
        /// 来源单号
        /// </summary>
        public string SourceSn { get; set; }
        /// <summary>
        /// 仓库Id
        /// </summary>
        public int? WarehouseId { get; set; }
        /// <summary>
        /// 仓库名称
        /// </summary>
        public string WarehouseName { get; set; }
        /// <summary>
        /// 仓位
        /// </summary>
        public string LocationCode { get; set; }
        /// <summary>
        /// 托盘号
        /// </summary>
        public string PalletBarcode { get; set; }
        /// <summary>
        /// 货主Id
        /// </summary>
        public int? OwnerId { get; set; }
        /// <summary>
        /// 货主名称
        /// </summary>
        public string OwnerName { get; set; }
        /// <summary>
        /// 物料Id
        /// </summary>
        public int? MaterialId { get; set; }
        /// <summary>
        /// 物料编码
        /// </summary>
        public string MaterialCode { get; set; }
        /// <summary>
        /// 物料名称
        /// </summary>
        public string MaterialName { get; set; }
        /// <summary>
        /// 批次号
        /// </summary>
        public string BatchNo { get; set; }
        /// <summary>
        /// 原始数量
        /// </summary>
        public decimal? StartQty { get; set; }
        /// <summary>
        /// 变更数量
        /// </summary>
        public decimal? ChangeQty { get; set; }
        /// <summary>
        /// 最终数量
        /// </summary>
        public decimal? EndQty { get; set; }
        /// <summary>
        /// 基本单元Id
        /// </summary>
        public int? BaseUnitId { get; set; }
        /// <summary>
        /// 单位名称
        /// </summary>
        public string BaseUnitName { get; set; }
        /// <summary>
        /// 备注
        /// </summary>
        public string Remark { get; set; }
        /// <summary>
        /// 生成日期
        /// </summary>
        public DateTime? CreateDate { get; set; }
        /// <summary>
        /// 创建人
        /// </summary>
        public int? CreateUserId { get; set; }
        /// <summary>
        /// 创建人
        /// </summary>
        public string CreateUser { get; set; }
    }
}
